<template>
	<view>
		<view class="jiaonang" :style="{ height: navHeight + 'px' }">
			<view class="jiaonang-box" :style="{ height: navObj + 'px', paddingTop:  navTop + 'px', paddingRight: (navObjWid+5)+ 'px' }">
				<view class="jiaonang-box-left" @tap="back()">
					<uni-icons class="jiaonang-box-left-img" type="arrow-left" color="#1abc9c" size="20"></uni-icons>
					<view class="jiaonang-box-left-txt">健康顾问档案</view>
				</view>
					<image class="jiaonang-box-fenxiang" @tap="goShare()" src="../../static/index/fenxiang.svg"  :style="{ height: navObj + 'px', width: navObj + 'px'}"/>
			</view>
		</view>
		<view class="content" :style="{ paddingTop: navHeight + 'px' }">
			<view class="content-title" :style="{ top: navHeight + 'px' }">
				<view class="content-title-item" @tap="itemClick(index)" v-for="(item,index) in arr" :key="item" :class="active == index?'content-title-active':''">{{item}}</view>
				<view class="content-title-line" :style="{ left: (active*80+ 25) + 'px' }"></view>
			</view>
			<view class="content-des">
				<view class="content-des-1" v-show="active==0">
					<view class="content-des-1-1">
						<view class="content-des-1-1-left">
							<view class="content-des-1-1-left-1">
								<view class="content-des-1-1-left-1-1">代用名</view>
								<view class="content-des-1-1-left-1-2">
									<image class="content-des-1-1-left-1-2-img" src="/static/index/renzheng.svg" mode=""></image>
									<view class="content-des-1-1-left-1-2-txt">已认证</view>
								</view>
							</view>
							<view class="content-des-1-1-left-2">
								<view class="content-des-1-1-left-2-item" v-for="item in 3" :key="item">{{item}}超级大的营养师</view>
							</view>
						</view>
						<image src="/static/index/1.png" class="content-des-1-1-right" mode=""></image>
					</view>
					<view class="content-des-1-2">
						5 年+从业经验，擅长慢病、四高、瘦身塑形、亚健康营养管理，至今已为1万多人制定过营养调理方案。具备深厚专业知识，涵盖基础、临床、公共及食品营养。能精准评估个体与群体营养状况并诊断问题，制定实施个性化与群体营养方案，善用多种方式教育沟通，参与研究创新实践，且可在跨学科团队中协作管理，推动营养事业发展。 
					</view>
				</view>
				<view class="content-des-2" v-show="active==1">
					<view class="content-des-2-item">
						<view class="content-des-2-item-left">
							<view class="content-des-2-item-left-1">姓名</view>
						</view>
						<view class="content-des-2-item-right">
							<view class="content-des-2-item-right-item">代用名</view>
						</view>
					</view>
					<view class="content-des-2-item">
						<view class="content-des-2-item-left">
							<view class="content-des-2-item-left-1">教育背景</view>
							<view class="content-des-2-item-left-2"></view>
						</view>
						<view class="content-des-2-item-right">
							<view class="content-des-2-item-right-item">中国中医药大学</view>
							<view class="content-des-2-item-right-item">营养与食品卫生学</view>
						</view>
					</view>
					<view class="content-des-2-item">
						<view class="content-des-2-item-left">
							<view class="content-des-2-item-left-1">专业资质</view>
							<view class="content-des-2-item-left-2"></view>
						</view>
						<view class="content-des-2-item-right">
							<view class="content-des-2-item-right-item">健康管理师</view>
							<view class="content-des-2-item-right-item">一级注册营养师</view>
						</view>
					</view>
					<view class="content-des-2-item">
						<view class="content-des-2-item-left">
							<view class="content-des-2-item-left-1">资质认证</view>
						</view>
						<view class="content-des-2-item-right">
							<view class="content-des-2-item-right-item">已认证</view>
						</view>
					</view>
					<view class="content-des-2-item">
						<view class="content-des-2-item-left">
							<view class="content-des-2-item-left-1">店铺二维码</view>
							<view class="content-des-2-item-left-2">下载二维码大图</view>
						</view>
						<view class="content-des-2-item-right">
							<image class="content-des-2-item-right-img" src="/static/index/1.png" />
						</view>
					</view>
				</view>
				<view class="content-des-3" v-show="active==2">
					<view class="content-des-3-item" v-for="(item, index) in skill" :key="index">
						<view class="content-des-3-item-top">
							<view class="content-des-3-item-top-left">{{item.title}}</view>
							<view class="content-des-3-item-top-right" @tap='contentClick(item)'>{{item.isOpen?'[收起]':'[查看]'}}</view>
						</view>
						<view v-show="item.isOpen" class="content-des-3-item-content">{{item.des}}</view>
					</view>
				</view>
				<view class="content-des-3" v-show="active==3">
					<view class="content-des-3-item" v-for="(item, index) in famous" :key="index">
						<view class="content-des-3-item-top">
							<view class="content-des-3-item-top-left">{{item.title}}</view>
							<view class="content-des-3-item-top-right" @tap='contentClick(item)'>{{item.isOpen?'[收起]':'[查看]'}}</view>
						</view>
						<view v-show="item.isOpen" class="content-des-3-item-content">{{item.des}}</view>
					</view>
				</view>
				<view class="content-des-5" v-show="active==4">
					<view class="content-des-5-title">
						<view class="content-des-5-title-left">单位名称</view>
						<view class="content-des-5-title-right">代用</view>
					</view>
					<view class="content-des-5-title">
						<view class="content-des-5-title-left">职务</view>
						<view class="content-des-5-title-right">代用</view>
					</view>
					<view class="content-des-5-title">
						<view class="content-des-5-title-left">起止时间</view>
						<view class="content-des-5-title-right">代用</view>
					</view>
					<view class="content-des-5-title">
						<view class="content-des-5-title-left">工作描述</view>
					</view>
					<view class="content-des-5-work">
						<view class="content-des-5-work-item" v-for="(item,index) in work" :key="item">{{index+1}}、{{item}}</view>
					</view>
					
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				navHeight: '',
				navTop: '',
				navObj: '',
				navObjWid: '',
				arr: [
					'简介','概况','专业技能','影响力','从业经历'
				],
				active: 3,
				skill: [
					{
						title: '精准营养评估与诊断',
						isOpen: false,
						des: '熟练运用多种先进评估技术和指标，如人体成分分析仪、血液生化指标（维生素 D、同型半胱氨酸等）检测，准确判断个体营养缺乏或过剩状况，并深入分析潜在健康风险，为制定精准营养干预方案提供科学依据。'
					},
					{
						title: '个性化营养方案定制',
						isOpen: false,
						des: '熟练运用多种先进评估技术和指标，如人体成分分析仪、血液生化指标（维生素 D、同型半胱氨酸等）检测，准确判断个体营养缺乏或过剩状况，并深入分析潜在健康风险，为制定精准营养干预方案提供科学依据。'
					},
					{
						title: '营养教育与沟通',
						isOpen: false,
						des: '熟练运用多种先进评估技术和指标，如人体成分分析仪、血液生化指标（维生素 D、同型半胱氨酸等）检测，准确判断个体营养缺乏或过剩状况，并深入分析潜在健康风险，为制定精准营养干预方案提供科学依据。'
					},
					{
						title: '营养产品研发与管理',
						isOpen: false,
						des: '熟练运用多种先进评估技术和指标，如人体成分分析仪、血液生化指标（维生素 D、同型半胱氨酸等）检测，准确判断个体营养缺乏或过剩状况，并深入分析潜在健康风险，为制定精准营养干预方案提供科学依据。'
					},
					{
						title: '团队领导与项目管理',
						isOpen: false,
						des: '熟练运用多种先进评估技术和指标，如人体成分分析仪、血液生化指标（维生素 D、同型半胱氨酸等）检测，准确判断个体营养缺乏或过剩状况，并深入分析潜在健康风险，为制定精准营养干预方案提供科学依据。'
					}
				],
				famous: [
					{
						title: '科研贡献',
						isOpen: false,
						des: '在国际知名营养学学术期刊（如《The Journal of Nutrition》《Nutrition Reviews》等）发表多篇研究论文，其中关于 [创新性营养研究成果] 的论文被广泛引用，为推动营养学领域的学术研究和临床实践发展做出了积极贡献。'
					},
					{
						title: '促进行业内知识共享和技术创新',
						isOpen: false,
						des: '在国际知名营养学学术期刊（如《The Journal of Nutrition》《Nutrition Reviews》等）发表多篇研究论文，其中关于 [创新性营养研究成果] 的论文被广泛引用，为推动营养学领域的学术研究和临床实践发展做出了积极贡献。'
					},
					{
						title: '助力行业建设与人才培养',
						isOpen: false,
						des: '在国际知名营养学学术期刊（如《The Journal of Nutrition》《Nutrition Reviews》等）发表多篇研究论文，其中关于 [创新性营养研究成果] 的论文被广泛引用，为推动营养学领域的学术研究和临床实践发展做出了积极贡献。'
					},
					{
						title: '推动了营养健康管理行业的规范化和专业化发展',
						isOpen: false,
						des: '在国际知名营养学学术期刊（如《The Journal of Nutrition》《Nutrition Reviews》等）发表多篇研究论文，其中关于 [创新性营养研究成果] 的论文被广泛引用，为推动营养学领域的学术研究和临床实践发展做出了积极贡献。'
					}
				],
				work: [
					'为高净值客户定制全方位营养健康管理方案，基于客户详细的健康体检数据、生活习惯调查以及基因检测报告（如有），提供精准的饮食规划、运动营养搭配建议以及压力与睡眠管理指导，助力客户实现个性化健康目标，如协助多位企业高管成功进行体重管理并改善因长期工作压力导致的亚健康状态。',
					'带领团队研发并优化机构专属的营养健康管理课程体系，包括线上线下营养讲座、互动式营养工作坊等，内容涵盖营养基础知识普及、季节性饮食养生、特殊人群营养呵护等多个领域，累计培训学员超过 [X] 人次，有效提升了公众营养健康意识和自我管理能力。',
					'负责机构营养产品的筛选与定制工作，依据最新营养学研究成果和客户需求，与国内外知名营养品牌合作，挑选优质营养补充剂，并为客户定制个性化营养套餐，同时对产品质量和功效进行严格把控与跟踪评估，确保产品安全有效且符合客户个性化需求。'
				]
			}
		},
		mounted() {
			const systemInfo = uni.getSystemInfoSync();
			let menuButtonObject = wx.getMenuButtonBoundingClientRect();
			let statusBarHeight = systemInfo.statusBarHeight
			let navTop = menuButtonObject.top
			let navObjWid = systemInfo.windowWidth - menuButtonObject.right + menuButtonObject.width // 胶囊按钮与右侧的距离 = windowWidth - right+胶囊宽度
			let navHeight = statusBarHeight + menuButtonObject.height + (menuButtonObject.top - statusBarHeight) * 2;
			this.navHeight = navHeight; //导航栏总体高度
			this.navTop = navTop; //胶囊距离顶部距离
			this.navObj = menuButtonObject.height; //胶囊高度
			this.navObjWid = navObjWid; //胶囊宽度(包括右边距离)
		
		},
		methods: {
			goShare() {},
			itemClick(index) {
				this.active = index
			},
			contentClick(item) {
				item.isOpen = !item.isOpen
			}
		}
	}
</script>
<style lang="scss">
	.jiaonang {
		width: 750rpx;
		position: fixed;
		top: 0;
		left: 0;
		z-index: 999;
		background-color: #fff;
		&-box {
			display: flex;
			justify-content: space-between;
			align-items: center;
			&-left {
				display: flex;
				align-items: center;
				&-img {
					margin: 0 5px
				}
				&-txt {
					font-size: 20px;
					font-weight: bold;
					color: #2A537C;
				}
			}
		}
	}
	.content {
		&-title {
			background-color: blue;
			height: 40px;
			line-height: 40px;
			width:100%;
			position: sticky;
			left: 0;
			background-color: #fff;
			white-space: nowrap;
			overflow-x: scroll;
			&-item {
				text-align: center;
				display: inline-block;
				width: 80px;
				font-size: 16px;
				color: rgba(42, 83, 124, 1);
				font-weight: 500;
			}
			&-active {
				color: #1ABC9C;
				font-weight: bold;
			}
			&-line {
				position: absolute;
				bottom: 0;
				height: 3px;
				width: 30px;
				background: rgba(0, 188, 141, 1);
				transition: all .3s;
				border-radius: 4px;
			}
		}
		&-des {
			padding: 10px;
			&-5 {
				background-color: #fff;
				border-radius: 10px;
				padding:20px 10px;
				&-title {
					display: flex;
					align-items: center;
					justify-content: space-between;
					padding: 10px 0;
					&-left {
						font-size: 16px;
						font-weight: 400;
						color: #7C92A8;
					}
					&-right {
						font-size: 16px;
						font-weight: 400;
						color: #2A537C
					}
				}
				&-work {
					padding: 10px;
					&-item {
						font-size: 16px;
						font-weight: 400;
						color: #2A537C;
					}
				} 
				
			}
			&-3 {
				background-color: #fff;
				border-radius: 10px;
				padding:20px 10px;
				&-item {
					border-bottom: 1px solid #F4F7FC;
					padding: 10px 0;
					&-top {
						display: flex;
						justify-content: space-between;
						align-items: center;
						&-left {
							font-size: 16px;
							font-weight: 700;
							color: #2A537C;
						}
						&-right {
							font-size: 14px;
							font-weight: 500;
							color: #00BC8D;
							width: 100px;
							text-align: right;
						}
					}
					&-content {
						font-size: 16px;
						font-weight: 500;
						color: #7C92A8;
						padding: 12px 0;
					}
				}
			}
			&-2 {
				background-color: #fff;
				border-radius: 10px;
				padding:20px 10px;
				&-item {
					display: flex;
					justify-content: space-between;
					padding: 12px 0;
					border-bottom: 1px solid #F4F7FC;
					&-left {
						display: flex;
						flex-direction: column;
						justify-content: space-between;
						&-1 {
							color: #7C92A8;
							font-size: 16px;
							font-weight: 400;
						}
						&-2 {
							font-size: 14px;
							color: #00BC8D;
							font-weight: 400;
						}
					}
					&-right {
						display: flex;
						flex-direction: column;
						justify-content: space-evenly;
						align-items: flex-end;
						&-item {
							color: #2A537C;
							font-size: 16px;
							font-weight: 400;
						}
						&-img {
							width: 72px;
							height: 72px;
						}
					}
				}
			}
			&-1  {
				background-color: #fff;
				border-radius: 10px;
				padding:10px;
				&-1 {
					display: flex;
					&-left {
						display: flex;
						flex-direction: column;
						width:calc(100% - 100px);
						&-1 {
							display: flex;
							align-items: center;
							&-1 {
								color: rgba(42, 83, 124, 1);
								font-weight: 900;
								font-size: 24px;
							}
							&-2 {
								display: flex;
								align-items: center;
								justify-content: space-between;
								background-color: rgba(26, 188, 156, 0.149);
								border-radius: 3px;
								padding: 0 8px;
								height: 26px;
								margin-left: 8px;
								&-img {
									width: 14px;
									height: 10px;
								}
								&-txt {
									color:#00BC8D;
									font-size: 12px;
									font-weight: 700;
									margin-left: 4px;
								}
							}
						}
						&-2 {
							display: flex;
							flex-wrap: wrap;
							margin-top: 4px;
							&-item {
								border-radius: 10px;
								color: rgba(42, 83, 124, 1);
								font-size: 14px;
								font-weight: 700;
								border: 2px solid rgba(235, 239, 246, 1);
								text-align: center;
								height:28px;
								line-height: 28px;
								padding: 0 6px;
								margin-left: 5px;
							}
						}
					}
					&-right {
						width:100px;
						height:100px;
						border-radius: 10px;
						float:right;
					}
					
				}
				&-2 {
					margin-top:10px;
					font-size: 14px;
					font-weight: 400;
					color: rgba(42, 83, 124, 1);
				}
				
			}
		}
	}
</style>

<style>

</style>
